package com.wish.wishhouse_resource.controller;


import com.wish.wishhouse_resource.entity.SysUser;
import com.wish.wishhouse_resource.service.ISysUserService;
import org.springframework.beans.factory.annotation.Autowired;
import jdk.nashorn.internal.ir.annotations.Reference;
import org.springframework.web.bind.annotation.RequestMapping;

import org.springframework.web.bind.annotation.RestController;
import vo.ResultEntity;

import javax.annotation.Resource;
import java.util.List;

/**
 * <p>
 * 系统用户 前端控制器
 * </p>
 *
 * @author zhangshuxin
 * @since 2021-03-28
 */
@RestController
@RequestMapping("/sysUser")
public class SysUserController {
    @Resource
    private ISysUserService sysUserService;


    @RequestMapping("/selectAllUserName")
    public ResultEntity selectAllUserName(){
        List<SysUser> list = sysUserService.list();

        return ResultEntity.ok("200",list);
    }

    @RequestMapping("select")
    public ResultEntity select(){
        List<SysUser> list = sysUserService.list();
        return ResultEntity.ok(list);
    }
}

